package com.cgq.base.service.impl;

import java.io.Serializable;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Component;

import com.cgq.base.dao.BaseDao;
import com.cgq.base.service.BaseService;

@Component
public abstract class BaseServiceImpl<T> implements BaseService<T> {

	protected BaseDao<T> baseDao;
	
	public void save(T entity) {
		baseDao.save(entity);
	}

	public void update(T entity) {
		baseDao.update(entity);
	}

	public void delete(Serializable... ids) {
		baseDao.delete(ids);
	}

	public T find(Serializable id) {
		return baseDao.find(id);
	}

}
